//2009/08/11 20:54:18
#include <string>
#include <vector>
#include <map>
#include <queue>
#include <algorithm>

using namespace std;

class StringMult
{
public:
    string times(string sFactor, int iFactor)
    {
		string s;
		if(sFactor.empty() || iFactor == 0) return "";
		for(int i=0; i<abs(iFactor); i++)
		{
			s += sFactor;
		}
		if(iFactor < 0)
		{
			string ss;
			for(int i=s.size()-1; i>=0; i--) ss += s[i];
			return ss;
		}
		return s;
    }
};
